home *** CD-ROM | disk | FTP | other *** search
/ Workbench Design / WB Collection.iso / workbench werkzeuge / memory & system tools / priman / priman.guide (.txt) < prev    next >
Amigaguide Document  |  1996-04-07  |  44KB  |  713 lines

  1. @Database PriMan.guide
  2. @Remark $VER: PriMan.guide 2.0 (13.11.94)
  3. @Node Main "Welcome to PriMan!"
  4.                   PriMan v2.0 - The Task Priority Manager
  5.                     Copyright 1993, 1994 Barry McConnell
  6.   @{" Distribution     " Link Distribution}  Something about setting off World War 3...
  7.   @{" Overview         " Link Overview}  Why PriMan exists, and what it does.
  8.   @{" Installation     " Link Installation}  Where do all these icons go?
  9.   @{" Usage            " Link Usage}  How to make it go PING!
  10.   @{" Author           " Link Author}  Barry wants to hear from you!
  11.   @{" Acknowledgements " Link Acknowledgements}  My director, my make-up artist, ...
  12.   @{" History          " Link History}  Things which happened aeons ago.
  13.   @{" Future           " Link Future}  PriMan will have them ... soon :-)
  14.                     @{fg shine}PriMan - Don't leave home without it!@{fg text}
  15. @Endnode
  16. @Node Distribution "Spread me far and wide"
  17. Distribution:
  18. This program is Freeware.  You may freely distribute it, and charge only a
  19. small fee to cover expenses.  It must remain unmodified, and accompanied by
  20. this doc file.
  21. I would like it if the source code followed PriMan around, but this is not
  22. strictly necessary.  The source is there for you to learn from - feel free to
  23. use small pieces of it in your own programs.  If you use it to create a new
  24. version of PriMan and then redistribute it, or if you use large portions of
  25. it in commercial software, I will naturally get @{" upset " Link Upset}.
  26. Fred Fish is explicitly given permission to place this program on his fine
  27. disk collection.  Urban Mueller may also do what he likes with it, Aminet-
  28. wise.
  29. If you like PriMan, or have any bug reports or suggestions, please send me a
  30. message via e-mail (or a postcard, if you don't have access to Internet or
  31. FidoNet).
  32. As with any free software, you use PriMan entirely at your own risk.  If you
  33. manage to start off World War 3 by discovering a bug, then I can not be held
  34. responsible...
  35. @Endnode
  36. @Node Overview "Hey, this is quite useful actually..."
  37. Overview:
  38. PriMan is a fully Style Guide-compliant program for viewing a list of all
  39. running tasks, and performing some actions on them.  The window in which the
  40. list appears can be resized, the fonts used can be chosen from a settings
  41. window, and customised settings can be stored in the ToolTypes.  PriMan
  42. requires at least Kickstart 2, and takes advantage of a few extra features
  43. available under Kickstart 3, although you probably won't notice these unless
  44. you examine the source code carefully. :-)
  45. PriMan allows you to change the priority of any task with the greatest of
  46. ease.  Unlike most other similar utilities, you need only drag a slider to
  47. change the priority - there is no messy clicking in string gadgets, deleting
  48. the old priority, and typing in a new one.  There is also the facility to
  49. signal tasks (e.g. with Ctrl-C), remove them from memory, and freeze them. 
  50. And if you like to have it handy all the time, there is an Iconify option, as
  51. well as the ability to leave it running in the background all the time as a
  52. Commodity.
  53. All of PriMan's functions are available using both the keyboard and the mouse.
  54. To find out some of the theory behind PriMan's use, @{" Click Here " Link Priority}.
  55. @Endnode
  56. @Node Installation "What do I do first?"
  57. Installation:
  58. PriMan itself is not fussy about where it goes.  If you like to have it
  59. running in the background all the time, I recommend placing it in WBStartup,
  60. ensuring the DONOTWAIT ToolType is set (see @{" ToolTypes " Link ToolTypes}), and configuring
  61. it not to open on startup (see @{" Commodity Settings " Link Commodity}).
  62. If you want the @{" Online Help " Link Help} facility, put PriMan.guide in the same directory
  63. as PriMan, or somewhere in your AmigaGuide path (see the file
  64. "ENVARC:AmigaGuide/PATH").
  65. If you have an older version of PriMan running as a Commodity, you will of
  66. course need to remove that before starting this version - if you don't, all
  67. that will happen is that the old version will pop to the front!
  68. @Endnode
  69. @Node Usage "Don't touch that button..."
  70. Usage:
  71.   @{" Starting Up     " Link Startup}
  72.   @{" Main Window     " Link MainWindow}
  73.   @{" Settings Window " Link Settings}
  74.   @{" ToolTypes       " Link ToolTypes}
  75.   @{" Online Help     " Link Help}
  76. @Endnode
  77. @Node Startup "Getting the ball rolling"
  78. Starting Up:
  79. PriMan works both from the Workbench and the Shell.  In both cases, it opens
  80. the PriMan.info file and gets the initial settings from the @{" ToolTypes " Link ToolTypes}.  If
  81. it can't find the .info file when running from the Shell, or some of the
  82. ToolTypes are missing, then it uses the internal defaults.
  83. When running from the Shell, you can specify any of the ToolTypes as command-
  84. line options, and these will override the ones in the .info file.
  85. Additionally, if the first command-line option is "?", PriMan will just give
  86. a short piece of help text and immediately exit.
  87. If you specify "HELP" as a ToolType or Shell command-line argument, the
  88. @{" Online Help " Link Help} facility will be used - PriMan will launch normally, and
  89. behave as if you pressed the Help key.
  90. When running from the Shell, if the .info file can't be found, then you won't
  91. be allowed to save your settings from the @{" Settings Window " Link Settings}.  Normally, the
  92. imagery for the AppIcon (when iconified) is the same as the .info file, but
  93. in this case it will use that of the system default tool (found in
  94. ENV:sys/def_tool.info).
  95. If you have configured PriMan to run as a @{" Commodity " Link Commodity}, and there is already
  96. another PriMan running as a Commodity, then the one just started will
  97. immediately exit, and the original one will bring itself to the front just as
  98. if you pressed its hotkey.
  99. If PriMan is running as a Commodity or has the @{" Iconify " Link General} option enabled, and
  100. the CX_POPUP @{" ToolType " Link ToolTypes} is set to NO, then the main window won't open, and
  101. PriMan will sit quietly in the background waiting for you to wake it up.
  102. PriMan responds to Ctrl-C signals, and if you send it one of these (e.g. from
  103. another running PriMan, or from the Shell it was started from), it will
  104. immediately abort (unless a system requester was open).  A Ctrl-F signal will
  105. tell it to open its main window (just like waking it up from Commodities
  106. Exchange).
  107. @Endnode
  108. @Node MainWindow "Playing God"
  109. Main Window:
  110. @{b}Task List@{ub}  The big task list gadget is where all the tasks are displayed,
  111. with their current priority in the second column.  You can use the mouse to
  112. scroll around the list and select tasks, or the up and down cursor keys to
  113. move through the list.  Shift-Up selects the first task in the list, and
  114. Shift-Down selects the last task.
  115. @{b}Update List@{ub}  This menu item updates the task list, which is useful if some
  116. tasks have been created or removed since PriMan last updated it. Note that this
  117. operation is very expensive, as it must disable task switching and
  118. interrupts, before walking through both of Exec's task lists, making a copy
  119. of each entry, and sorting them into alphabetical order.  Thus you may get a
  120. serial error if you are doing a modem transfer, or the pointer may "flash" if
  121. you are using @{" LacePointer " Link LacePointer} on a slow Amiga.  I have tried to optimise the code
  122. as much as possible to ensure this won't normally happen.  You can also use
  123. the Space and Return keys to update the list.
  124. @{b}Priority@{ub}  To change the currently-selected task's priority, use the slider
  125. gadget below the task list.  You can drag the slider and let go to make a big
  126. change in the priority (the priority will be changed when you let go), or
  127. click to the left or right of it to change the priority in steps of one.  You
  128. can also use the right and left cursor keys to increment and decrement the
  129. priority, respectively.  Pressing Shift at the same time moves to the
  130. extremities of the slider.
  131. The Priority menu item has a few presets, which could be quicker than
  132. dragging the slider.  A useful shortcut is "Amiga =" which sets the priority
  133. to zero.
  134. @{b}Wide Slider@{ub}  Normally, the priority slider gadget displays task priorities
  135. between -25 and +25, as it is unusual to find a task with an extremely low or
  136. extremely high priority.  By checking this menu item, the full scale can be
  137. used, allowing you to move the slider outside the -25 to +25 range.  This
  138. operation is done automatically if you select a task that happens to have a
  139. priority outside this range, and the menu item will also be disabled until
  140. you move the slider back inside the range (since you can't have a narrow
  141. scale when the current priority is large!).
  142. @{b}Signal@{ub}  A task can be signalled with any of the following:
  143. - Ctrl-C (please abort)
  144. - Ctrl-D (task-specific; often means disable)
  145. - Ctrl-E (task-specific; often means enable)
  146. - Ctrl-F (show yourself; used mostly with Commodities)
  147. Only Ctrl-C is widely-used by Amiga programs, and if you want to remove a
  148. task, you should try this first.  It is a nice way of letting something know
  149. you want it to finish, as it gives it a chance to clean up after itself.
  150. PriMan will wait for half a second after sending the signal, to give the task
  151. a chance to exit, before updating the task list.  If the task doesn't listen
  152. for Ctrl-C signals, nothing will happen.
  153. All four of these signals can be sent using the Signal menu item.  They have
  154. the obvious keyboard shortcuts Ctrl-C, Ctrl-D, etc.  Additionally, the Break
  155. button below the slider sends a Ctrl-C signal to the current task.
  156. If you hold down Shift while using any of these (e.g. Shift-Ctrl-C, or Shift
  157. while clicking on the Break button), the "Really signal ...?" confirmation
  158. requester will not appear.
  159. @{b}Kill@{ub}  The Kill button (or menu item) is nastier than sending a Ctrl-C signal,
  160. as it doesn't give the task a say in the matter.  It just removes it from
  161. memory, meaning any memory regions may not be freed up, resources will not be
  162. available to other tasks, etc.  You should only really use this as a last
  163. resort for tasks that have gone out of control.
  164. Note that removing a task that has exited since PriMan's display was last
  165. updated is NOT a good idea!  PriMan does some simple checking to ensure you
  166. don't do this, but it is not 100% foolproof.  (98%, actually. :-) )  If your
  167. Amiga crashes because you told PriMan to remove a non-existent task, you have
  168. nobody to blame but yourself...
  169. If the task has any windows or screens open, PriMan will ask you if you want
  170. to close them as well.  Likewise, it is not a good idea to answer "yes" to
  171. this question if, since putting up the requester, the windows or screens have
  172. already been closed.  Your Amiga will certainly crash if you do this.
  173. @{b}Frozen@{ub}  It is possible to "freeze" a task, and later let it resume execution.
  174. If you check this menu item, the current task gets frozen.  You can even quit
  175. PriMan and come back later to melt it (by unchecking it)!  Frozen tasks are
  176. bracketed in the task list.  Since AmigaOS does not contain this feature, I
  177. had to do a bit of "heavy magic" to get it to work.  So I don't guarantee the
  178. reliability of this option under future OS releases (although it should
  179. work).  Note that even if a task is frozen, messages sent to it (e.g.
  180. keypresses in a text editor) will still be received once it wakes up!
  181. @{b}Size Gadget@{ub} (lower right border of window)  You can make the window small
  182. enough to accommodate only two tasks in the list, or large enough to fill the
  183. screen.  All the gadgets in the window will be redrawn to fit in with the new
  184. window size.  PriMan will automatically perform an Update List if you resize
  185. the window, attempting to keep the current task selected, and leaving roughly
  186. the same part of the task list visible.  (It is better at this under
  187. Kickstart 3).
  188. @{b}Settings@{ub}  This button (or menu item) will open up the @{" Settings Window " Link Settings}.
  189. @{b}About@{ub}  This menu item brings up some additional information.  Clicking
  190. the Help button in the requester will start PriMan's @{" Online Help " Link Help}.
  191. @{b}Hide@{ub}  If you have PriMan running as a @{" Commodity " Link Commodity}, or with the @{" Iconify " Link General}
  192. option enabled, this menu item will close down its windows but leave it
  193. running in the background.  This is the same as clicking the close gadget on
  194. the main window.  If PriMan is not running as a Commodity and can't be
  195. iconified, Hide will be ghosted, and clicking the close gadget performs a
  196. Quit (below).
  197. @{b}Quit@{ub}  This menu item will also close down PriMan's windows, but in addition
  198. unloads it from memory.  This is how you would kill PriMan for good if you
  199. have the Commodity or Iconify options enabled.  The Escape key also performs
  200. this task, and works from both the main window and the @{" Settings Window " Link Settings}. 
  201. Please be gentle with this feature. :-)
  202. @Endnode
  203. @Node Settings "Customising your very own PriMan"
  204. Settings Window:
  205. The settings window is where you configure PriMan.  The main window can still
  206. be used while this window is open.  It is divided into three pages, which can
  207. be switched between using the Page cycle gadget at the top of the window.
  208.   @{" Interface " Link Interface}
  209.   @{" Commodity " Link Commodity}
  210.   @{" General   " Link General}
  211. Three buttons (at the bottom of the window) are common to each page:
  212. @{b}Save@{ub}  This will write out your settings (including window size and position)
  213. to PriMan's @{" ToolTypes " Link ToolTypes}.  Any ToolTypes already present that PriMan
  214. does not recognise will be preserved.  If you have changed the window type or
  215. chosen a new font, the main window will be redrawn.
  216. @{b}Use@{ub}  PriMan will use these settings, but not write them out to disk.
  217. @{b}Cancel@{ub}  Go back to the main window without making any changes.
  218. @Endnode
  219. @Node Interface "What shall I wear today?"
  220. Interface Settings:
  221. @{b}Gadget Font@{ub}  This will bring up the standard ASL Font requester, where you
  222. can select the font used for all the buttons.
  223. @{b}List Font@{ub}  A different (non-proportional) font needs to be used for the
  224. task list, as otherwise the second column would not line up properly. This is
  225. where you select it.
  226. @{b}Window Type@{ub}  Amiga windows can be one of two different types.  Smart Refresh
  227. windows maintain an off-screen bitmap of the entire window at all times, so
  228. if part of it is obscured by another window, and later revealed, the OS just
  229. copies the bitmap back into the window.  Simple Refresh windows don't have
  230. this off-screen bitmap, and hence it is the application's responsibility to
  231. refresh the window when necessary.  This is done by redrawing the individual
  232. gadgets.  The disadvantage here is that if the application is tied up doing
  233. something else (e.g. a system requester is open), its window won't get
  234. refreshed until later.
  235. On slow Amigas, Smart Refresh windows are faster.  If you have an accelerated
  236. Amiga (or graphics card), you may find Simple Refresh windows more
  237. responsive.  Try PriMan with both options (perform some window resizing,
  238. dragging, and hiding behind other window) and see which suits you best.
  239. @{b}Open On@{ub}  This simply tells PriMan on what screen it should open.  Default
  240. Screen uses the default public screen (typically the Workbench screen), while
  241. Front Screen uses the frontmost screen (assuming it's a public screen).
  242. @Endnode
  243. @Node Commodity "Catch me if you can!"
  244. Commodity Settings:
  245. By running it as a Commodity, you can leave PriMan quietly sitting in the
  246. background, and open it at the touch of a key.  If PriMan's window is already
  247. open and you use its hotkey, it will bring itself to the front.  PriMan will
  248. also check what screen it is supposed to be on (using the @{" Open On " Link Interface} setting),
  249. and jump to the correct screen if necessary.  This means you can, for
  250. example, set Open On to Front Screen, and have PriMan follow you around as
  251. you move between (public) screens, just by pressing its hotkey each time!
  252. Note that if you have the settings window open while PriMan is jumping
  253. between screens, it will re-open on the destination screen, but you will lose
  254. any changes you have made since you last clicked Save or Use.  Sorry!
  255. @{b}Install as a Commodity@{ub}  Should you not want PriMan to be a Commodity, you can
  256. deselect this checkbox.  Note that when you click the Save or Use buttons
  257. (see above), PriMan will install or remove itself as a Commodity, depending
  258. on this setting.  If it tries to install itself, and finds another copy of
  259. PriMan already installed, it will quietly exit, and the first copy will bring
  260. itself to the front.
  261. @{b}Popup When Launched@{ub}  If you are putting PriMan into your WBStartup drawer,
  262. you may like to have this option deselected, so it will be silently started
  263. each time you boot your Amiga.  Note that this option is ignored if you don't
  264. have one (or both) of @{" Iconify When Closed " Link General} and Install as a Commodity
  265. selected, as otherwise there would be no way of letting PriMan know when you
  266. want it to open its window!
  267. @{b}Hotkey@{ub}  If you have PriMan running as a Commodity, this is the keypress you
  268. use to open its window.  Check out your Workbench manual to see the
  269. acceptable combinations of keypresses.  If you give an invalid combination,
  270. you will get a warning requester, although PriMan will continue on as normal.
  271. @{b}Priority@{ub}  This is the Commodity priority PriMan runs at.  It is best left at
  272. zero, and only really comes into play when two Commodities try to allocate
  273. the same hotkey for themselves.  Note the difference between the Commodity
  274. Priority and the @{" Task Priority " Link General}!
  275. @Endnode
  276. @Node General "The boring stuff"
  277. General Settings:
  278. @{b}Task Priority@{ub}  This is the Exec task priority PriMan runs at.  Most ordinary
  279. applications run at a priority of 0 (and share CPU time amongst themselves).
  280. System tasks run at higher priorities, to be guaranteed of getting CPU time
  281. when they need it (which isn't too often).  If you are using PriMan to kill
  282. off tasks which are chewing CPU time (e.g. they've gone into an infinite
  283. loop), it is good idea to run it at a higher priority.  Once you have
  284. verified that PriMan itself doesn't go into infinite loops ( :-) ), feel free
  285. to set its priority to (say) 5, so it is always as responsive as possible,
  286. regardless of what else is happening in your system.  The range is from -127
  287. to +128.
  288. If you change PriMan's priority from the @{" Main Window " Link MainWindow}, and then come here,
  289. you will find the Task Priority box has been updated accordingly.
  290. @{b}Confirm Actions@{ub}  If you are afraid of accidentally signalling or removing
  291. a task, select this checkbox.  PriMan will then ask you for confirmation
  292. before performing either of these actions.
  293. @{b}Iconify When Closed@{ub}  If this is selected, whenever you click the close
  294. gadget on the @{" Main Window " Link MainWindow}, an AppIcon will be placed on the Workbench
  295. screen.  Double-clicking on this will open the main PriMan window again.
  296. @Endnode
  297. @Node ToolTypes "Carving your settings in stone"
  298. ToolTypes:
  299. PriMan takes its settings from the ToolTypes, held in the PriMan.info file
  300. (accessed from Workbench by choosing the Get Info menu option).  Valid
  301. ToolTypes include:
  302.   @{fg shine}LEFT@{fg text}          left edge of window
  303.   @{fg shine}TOP@{fg text}           top edge of window
  304.   @{fg shine}WIDTH@{fg text}         window width
  305.   @{fg shine}HEIGHT@{fg text}        window height
  306.   @{fg shine}GADFONT@{fg text}       font used for gadgets (e.g. "Topaz.font")
  307.   @{fg shine}GADSIZE@{fg text}       height of GADFONT
  308.   @{fg shine}LISTFONT@{fg text}      non-proportional font used in the task list
  309.   @{fg shine}LISTSIZE@{fg text}      height of LISTFONT
  310.   @{fg shine}ICONLEFT@{fg text}      left position of AppIcon
  311.   @{fg shine}ICONTOP@{fg text}       top position of AppIcon
  312.   @{fg shine}REFRESH@{fg text}       SMART|SIMPLE - the @{" Window Type " Link Interface} setting
  313.   @{fg shine}SCREEN@{fg text}        DEFAULT|FRONT - the @{" Open On " Link Interface} setting
  314.   @{fg shine}CONFIRM@{fg text}       YES|NO - the @{" Confirm Actions " Link General} setting
  315.   @{fg shine}ICONIFY@{fg text}       YES|NO - the @{" Iconfiy When Closed " Link General} setting
  316.   @{fg shine}COMMODITY@{fg text}     YES|NO - the @{" Install as a Commodity " Link Commodity} setting
  317.   @{fg shine}HELP@{fg text}          if present, @{" Online Help " Link Help} is given at startup time
  318. The standard @{" Commodity " Link Commodity} ToolTypes also apply:
  319.   @{fg shine}CX_POPUP@{fg text}      YES|NO - the Popup When Launched setting
  320.   @{fg shine}CX_POPKEY@{fg text}     hotkey to open PriMan's window (or bring it to the front)
  321.   @{fg shine}CX_PRIORITY@{fg text}   Commodity priority
  322. Not forgetting some of the ones Workbench uses:
  323.   @{fg shine}TOOLPRI@{fg text}       PriMan's @{" Task Priority " Link General}
  324.   @{fg shine}DONOTWAIT@{fg text}     you need this if PriMan goes in WBStartup
  325. PriMan's internal defaults will be used for any ToolTypes that are missing.
  326. If you don't specify both a name and a height for either of the fonts, then
  327. PriMan will use your Workbench Preferences settings for that font.  If it
  328. can't find the font you ask for, you will get a warning requester, and
  329. Topaz-8 will be used.
  330. If you are a Shell user, you can put your favourite settings in the
  331. ToolTypes, run PriMan just by typing "PriMan" (assuming it's somewhere in
  332. your path), and - if necessary - override individual ToolTypes by passing
  333. them as Shell arguments in the same format as above.
  334. Note that you should never need to manipulate the ToolTypes directly yourself!
  335. Let the @{" Settings Window " Link Settings} take care of this.  The only ToolTypes not currently
  336. controllable from the settings window are the ones relating to the position
  337. of the AppIcon - edit the PriMan.info file yourself if you need to put the
  338. AppIcon in a specific place on the Workbench screen.
  339. @Endnode
  340. @Node Help "What on earth does this do?"
  341. Online Help:
  342. PriMan has an interface to AmigaGuide, and - assuming PriMan.guide is
  343. available (see @{" Installation " Link Installation}) - will open it whenever you ask for help.  This
  344. is done by pressing the Help key from either the @{" Main Window " Link MainWindow} or the
  345. @{" Settings Window " Link Settings}, clicking Help in the About requester, or passing "HELP" as
  346. a ToolType or Shell command-line argument.
  347. The AmigaGuide window runs as a separate process, which means you can
  348. continue to use PriMan while it's open.  Pressing the Help key again will
  349. always bring you back to the first page in the help text.  Additionally, if
  350. PriMan has moved to a different screen in the meantime, the AmigaGuide window
  351. will follow it when you press Help.
  352. The AmigaGuide handler I've written is quite simplistic, and it ignores any
  353. errors.  So if PriMan.guide can't be found, nothing will happen.
  354. Online help requires amigaguide.library, which you may not have installed if
  355. you are still using Kickstart 2.04.
  356. @Endnode
  357. @Node Author "My people will be in touch with your people"
  358. Contacting Me:
  359. I can be reached via any of the following methods:
  360. @{" Snail Mail " Link Snail}    Barry McConnell,
  361.         "Piper's Hollow",
  362.         Hillcrest Road,
  363.         Dublin 18,
  364.         Ireland.
  365. @{" Internet " Link Internet}    bmccnnll@tcd.ie  (note new short address!)
  366. @{" FidoNet " Link Fidonet}    2:263/150.2
  367. My Internet address probably won't be valid after October 1995.
  368. @Endnode
  369. @Node Acknowledgements "Eternal gratitude"
  370. Thanks:
  371. I am deeply indebted to Eddy Carroll for giving me a lot of programming tips
  372. while I was writing PriMan.  It was great having such a helpful Amiga guru
  373. just an e-mail away; any interface similarities to @{" SnoopDos " Link SnoopDos} may be not
  374. entirely coincidental. :-)
  375. A big `thankyou' to James Young for doing the AmigaGuide conversion of the
  376. doc file.  I never considered it necessary for PriMan to have documentation
  377. in this format, but when I saw the final result, I liked it so much, I
  378. scrapped the original ASCII doc file. ;-)
  379. Thanks to my beta-testers: Eddy Carroll, Colin Dalton, Andrew Mowatt, Niall
  380. Murphy and Kevin Phair.
  381. Thanks to Tom Ekstr
  382. m for the icon, and to Wouwe van AP for the one I didn't
  383. Also thanks to everyone else who gave me feedback and ideas - you're all
  384. mentioned in the History section.
  385. SAS/C was used to create PriMan, purchased at the student price from the fast
  386. and efficient SAS Germany.
  387. @Endnode
  388. @Node History "It happened like this..."
  389. History:
  390.   @{" Version 1.0 " Link v1.0}  3rd September 1993
  391.   @{" Version 1.1 " Link v1.1}  29th September 1993
  392.   @{" Version 2.0 " Link v2.0}  13th November 1994
  393. @Endnode
  394. @Node v1.0 "A child is born!"
  395. Version 1.0:
  396. - Initial release.
  397. @Endnode
  398. @Node v1.1 "What v1.0 should have been"
  399. Version 1.1:
  400. - Now complains if you try to "Break" or "Kill" it.
  401. - Walks through Intuition's list of screens and windows when removing a task.
  402.   If it finds any open windows belonging to that task, it asks you if you
  403.   want to close them as well.  Currently doesn't close screens, because that
  404.   is even more dangerous. :-)
  405. - Moved around the code for building the task list, taking almost everything
  406.   out of the Disable() ... Enable() section.  Now it just generates an array
  407.   of pointers to the tasks when interrupts are disabled, and does the actual
  408.   sorting later on.  This means your pointer is less likely to flash if you
  409.   are using LacePointer, and serial I/O will be not be affected as badly. 
  410.   Thanks to David Swasbrook for giving me the incentive to do this.
  411. - Added in error messages if PriMan has to suddenly abort for any reason.  If
  412.   you are _really_ low on memory, you may not get them...
  413. - The settings window is now the same width as the main window, so PriMan no
  414.   longer has to look at the width of the Gadget font when trying to fit a
  415.   decent number of characters into the font boxes.  Thanks to James Young for
  416.   spotting that PriMan did not work well with the Junod 8 point font (from
  417.   the AmigaGuide archive).  The font structure appears to be flawed, and
  418.   reports that it can be a maximum of 258 pixels wide...
  419. - Fixed bug where you could still resize the main window when the "About"
  420.   requester was open.
  421. - Major changes to code means PriMan is now more multithreaded.  You can have
  422.   the settings window (but not any system requesters) open, and still play
  423.   around with the main window.
  424. - Added an AppIcon feature, which can be turned on from the settings window. 
  425.   If enabled, closing the main window will place an AppIcon on the Workbench
  426.   screen, and double-clicking that will open the main window again.  To leave
  427.   PriMan for good, press Escape.
  428. - PriMan now accepts arguments from the Shell.
  429. - Added a Commodity interface.  PriMan does everything you would expect when
  430.   you play around with the Commodities Exchange program.  If you try
  431.   launching PriMan twice, the original one will be de-iconified (if
  432.   necessary) and then brought to the front.  The enable/disable buttons in
  433.   Exchange do nothing to PriMan.  Pressing Escape in PriMan also removes it
  434.   for good (like when using the Iconify option).
  435. @Endnode
  436. @Node v2.0 "Now the users are getting picky..."
  437. Version 2.0:
  438. It took me a while to get this one out the door (over a year!), due to the
  439. demands of college and other committments.  I hope I remembered to include
  440. all the changes I made!
  441. - Source code has been cleaned up a LOT.  I liberally sprinkled comments all
  442.   around it, and in doing so did heaps of rewriting.  (It's amazing how
  443.   commenting your code forces you to think clearly about exactly what you're
  444.   doing, and then you often find a better way...)  Note that the source is
  445.   now in several files, and has its own makefile.
  446. - Added menus, specially for Per Jacobsen. :-)
  447. - Added keyboard shortcuts for all the gadgets.  Thanks to Eddy Carroll for
  448.   showing me how to simulate buttons being pressed when their shortcut is
  449.   used.  The cursor keys are also used: up and down move you through the
  450.   task list, while left and right change the currently-selected task's
  451.   priority.  Holding down Shift moves you to the extremity of the task list
  452.   or slider gadget.
  453. - Fixed an error in the error-handling routine. :-)  Sometimes if a really
  454.   nasty error occurred (like running out of memory while trying to open the
  455.   settings window), PriMan would forget to clean up after itself, and do
  456.   wierd things if you tried playing with its window after the main task had
  457.   exited.  Thanks to James Young for bringing this one to my attention (the
  458.   only real bug in v1.1).
  459. - Removed the close gadget on the settings window, since its meaning is not
  460.   clear.  (Should it perform a Use or Cancel operation?  Standard Commodore
  461.   requesters perform a Cancel where appropriate, but this is not immediately
  462.   obvious for the new user.)  Note that it does still check for any
  463.   IDCMP_CLOSEWINDOW events (Eddy Carroll's idea), so you can cancel it using
  464.   something like WindowDaemon's Ctrl-\ shortcut.  (Although it's probably
  465.   easier to just press 'C'!)
  466. - Now watches for Ctrl-C signals (say from another PriMan...), and
  467.   immediately aborts when one is received.  Thanks to Karl Jeacle for
  468.   expressing horror when he noticed v1.1 didn't do this. :^)
  469. - New default hotkey "control alt p" to conform to other Commodore
  470.   Commodities.  Thanks to Matt Brookes for suggesting this.
  471. - Now uses the title bar to indicate the number of tasks listed. Thanks to
  472.   David Swasbrook for this idea.
  473. - Moved around the code for generating the task list _again_, just to please
  474.   David Swasbrook. ;-)  He was unhappy with the (negligible, IMHO) chance of
  475.   a task exiting after interrupts had been re-enabled, but before its name
  476.   had been placed into the sorted list (meaning when PriMan went to reference
  477.   its structure from the pointer table it had built earlier, wierd things
  478.   could happen).  So now PriMan builds a list of task pointers while
  479.   interrupts are disabled, copies their names and priorites while interrupts
  480.   are enabled but multitasking disabled, and finally sorts the list after
  481.   re-enabling multitasking.  (See the source code for more detail on this.)
  482.   This means the system is locked up for slightly longer than in v1.1 (but
  483.   nowhere near as long as in v1.0); however there is no discernible difference
  484.   on my A3000, and I hope this is okay for 68000 users.
  485. - Added shortcuts to bypass the confirmation requesters when signalling or
  486.   removing tasks, for Kevin Phair.  If you hold down Shift when selecting the
  487.   Break or Kill buttons (or menus), you don't get the requester.  Thanks to
  488.   Eddy Carroll for a little bit of help here.
  489. - Now has the option to close screens as well as windows, for Niall Murphy.
  490.   (I was going to do it anyway, okay Niall?)
  491. - Settings window has a new "Task priority" gadget, where you can enter the
  492.   priority you want PriMan to run at.  This functionality was always
  493.   available via the standard Workbench TOOLPRI ToolType, but since many
  494.   people (Kevin Phair @{i}et al@{ui}) didn't know about this, I have now made it
  495.   explicit.
  496. - Added menu items to change the task priority to preset values, for Panu
  497.   Hassi.  A bit simplistic at the moment, since the presets are hard-coded.
  498. - Now has the option to freeze tasks.  This idea came from Burnand Patrick -
  499.   thanks for your postcard, Burnand!  In a @{" Usenet " Link Usenet} article, Ingo Wilken
  500.   described how to do this, and I am very grateful to him.
  501. - The settings and font windows are now indented a little from their parents,
  502.   since Niall Murphy gets less confused this way. :)
  503. - Minor bugfix (okay, the *second* bug in v1.1).  PriMan had the potential to
  504.   get very confused if it was started from Workbench, but didn't find a .info
  505.   file.  Thanks to Eddy "hawk-eyes" Carroll for spotting the spurious
  506.   semicolon at the end of an 'if' statement in my source. :-)
  507. - PriMan is now Virtual Memory friendly.  Where memory is used while
  508.   interrupts are disabled, it is allocated as PUBLIC memory.  This will make
  509.   programs such as VMM much happier.  Thanks for the beta copy of VMM030,
  510.   Martin Aspel!
  511. - PriMan is 'sysihack'-aware.  It adjusts if the bottom border of its window
  512.   becomes larger than the 2.x/3.x defaults.  Thanks to Eddy for showing me
  513.   the easiest way of doing this.  (See the source code!)
  514. - All-new settings window.  I figured there were too many options to display
  515.   in one window without potentially confusing the casual user, so it now
  516.   displays one page at a time, out of three.
  517. - Rather than always opening on the default public screen, PriMan now has the
  518.   option to open on the front screen instead.  If the front screen is not a
  519.   public screen, it opens on the default public screen anyway.  I also added
  520.   a little bit of code to check the default or front screen when PriMan's
  521.   hotkey is pressed but its window is already open, and reopen its window if
  522.   the screen it's currently on is not the "correct" one.  Actually, this is a
  523.   blatant rip-off of the way SnoopDos 3.0 works - thanks, Eddy!
  524. - Now lets you choose if you want a SIMPLE_REFRESH or SMART_REFRESH window.
  525. - Signal menu item lets you choose which signal to send to a task, or you can
  526.   just press Ctrl and the signal type.  PriMan itself responds to the standard
  527.   Commodity Ctrl-F signal (meaning "show yourself").  It was Wouwe van AP's
  528.   idea to allow sending signals other than Ctrl-C.
  529. - The font requesters are smarter: the first one to open takes up 2/3 of the
  530.   current screen's height, and the second one will take its initial
  531.   dimensions from the first one.  Thanks to Eddy for his suggestion.
  532. - Additionally, if PriMan can't find any settings at all, it uses similar
  533.   screen-related code to determine sensible initial window dimensions and
  534.   positions.  (See the source code!)
  535. - Changed the Commodity code a bit so the CX_PRIORITY will get updated
  536.   immediately if you change it from settings, rather than the next time you
  537.   launch PriMan.  The side-effect is that - where applicable - PriMan now
  538.   quickly removes itself as a Commodity then adds itself back in whenever you
  539.   click Use in the settings window.
  540. - If you click on a task, then update the list (either by selecting the Update
  541.   List menu or its keyboard equivalents; or by resizing the window), the task
  542.   will remain selected afterwards (assuming it still exists).
  543. - PriMan now has online help.  If you press the Help key, AmigaGuide goes off
  544.   and looks for the PriMan.guide file.  It even follows PriMan around screens:
  545.   if you jump to a different screen and press Help, the AmigaGuide file will
  546.   follow you.  A quick peek at SnoopDos's source clarified how to get
  547.   asynchronous AmigaGuide support working.  HELP is now a ToolType (and works
  548.   from the Shell) if you want online help at startup time.
  549. - More support for Shell users (at Eddy's request).  PriMan first looks for
  550.   its .info file, and reads in the ToolTypes from that.  Then if you specify
  551.   any additional arguments on the command line, they will override the
  552.   ToolTypes.  If the first argument is "?", you'll get a short help message
  553.   and PriMan will exit.  Finally, clicking Save in the settings window will
  554.   write the current settings out to the .info file.  Naturally, if it can't
  555.   find this then the Save button will be ghosted as before, but you can still
  556.   use the Iconify option, and this will use the imagery of the system default
  557.   Tool icon (ENV:sys/def_tool.info).
  558. - Phew!  After all this, the executable has barely increased in size since
  559.   the last version, due to some clever optimisation...
  560. @Endnode
  561. @Node Future "Things worth considering"
  562. Future Additions:
  563. - String gadget to enter a new priority.  (Matt Brookes)
  564. - MultiUserFS support: indicate task's owner somewhere.  (David Swasbrook)
  565. - Icon position window a la ToolManager, so you can precisely position the
  566.   AppIcon instead of by trial-and-error.  (The ToolTypes to control its
  567.   location are the only ones you need to manually change from the Workbench
  568.   Info menu.)  (Andrew Mowatt)
  569. - Indicate CPU usage, or at least whether a task is awake or asleep.  (Kevin
  570.   Phair)
  571. - Allow iconifying to the Workbench Tools menu, if anyone asks for this.
  572. - Improve the AmigaGuide handler, so it reports errors, etc.
  573. Things I don't plan to do include:
  574. - Full context-sensitive online help.  (It isn't really necessary!)
  575. - Anything not directly related to tasks (e.g. lists of devices or
  576.   libraries), the reason being PriMan is supposed to be a small Commodity
  577.   with a fairly focused purpose in life.
  578. - Programmer info (e.g. a dump of the task's structure).  There are plenty of
  579.   other utilities out there if you really need this - PriMan is intended to be
  580.   the kind of thing that would have been included in the OS if the designers
  581.   had had more time...
  582. @Endnode
  583. @Node Priority "So you're still not convinced?"
  584. Why Do I Need PriMan?
  585. The Amiga is a multitasking computer.  This means that while it only has one
  586. CPU (one of the M680x0 series), it can - seemingly - run many programs at the
  587. same time.
  588. To get a simple idea of how this works, imagine a certain part of the OS is
  589. in control of the CPU.  It has a list of all the running programs (tasks),
  590. and allots a fixed amount of time to each one.  When one task runs out of
  591. time, it is suspended and the next one gets to run.  With small-enough time
  592. slices, this gives the illusion that all are running at the same time.
  593. Tasks actually spend most of their time doing nothing (waiting for the user
  594. to press a key, waiting for a disk operation to complete, etc.).  So the OS
  595. maintains two lists: one for tasks that are doing something (e.g. your
  596. ray-tracer doing a rendering operation), and the other for tasks that are
  597. waiting for something to happen or an operation to complete (e.g. your
  598. word-processor when you aren't using it).
  599. The more tasks on the "ready" list (doing something), the more loaded your
  600. Amiga is, and less responsive it appears to get.  By judicious use of task
  601. priorities, you can maximise its performance.
  602. Each task has a priority, between -128 and +127, with 0 being the usual.  Put
  603. simply: the OS divides up the available CPU time between the tasks with the
  604. highest priority, and ignores the rest.  If all tasks are running at priority
  605. 0, then they all get equal time.  Some important system tasks (e.g. Workbench
  606. or your hard disk controller) are put at higher priorities.  These spend most
  607. of their time asleep, but when they need to run, they get the CPU pretty much
  608. immediately (whatever task was currently running at a lower priority gets
  609. suspended to make way for the higher-priority task).
  610. As it turns out, the most important (system) tasks don't need to run very
  611. often, and it's quite safe to leave them at high priorities (this is done
  612. automatically).  Whenever you launch an application, it gets put at priority
  613. 0 by default.
  614. Where PriMan comes in handy is when you have - say - a ray-tracer running for
  615. several hours.  If you try to do something else (say word-processing) with
  616. the ray-tracer in the background, it will be slowed down since it's sharing
  617. CPU time with the ray-tracer.  By using PriMan to lower the ray-tracer's
  618. priority to (say) -1 or -5, your word-processor will get all the CPU time it
  619. needs, and when it's not processing your keypresses or doing some printing,
  620. the ray-tracer will get back its CPU time.
  621. Of course, PriMan has a host of other features, such as being able to signal
  622. tasks, kill them, freeze them ... so why not drop it in your WBStartup drawer
  623. right now? :-)
  624. @Endnode
  625. @Node Upset "Not for the faint-hearted"
  626. Getting upset:
  627. Some folk, when they get upset in this manner, go to great lengths in order
  628. to (legally) extract large amounts of money from you.  Others will force you
  629. to suffer public humiliation.  Still others will shoot your dog.  Pick your
  630. personal worst-case scenario, then don't break my rules for distributing
  631. PriMan. :^)
  632. @Endnode
  633. @Node Snail "Has it arrived yet?"
  634. Snail Mail:
  635. Snail Mail is the term used by e-mail junkies - who are used to messages being
  636. beamed around the world in a matter of minutes (or seconds) - to describe
  637. "normal" mail.  That is, mail which you put in an envelope, put a stamp on,
  638. and deposit in a mail box, then wait "only" a week for it to get from Ireland
  639. to the UK. :-)
  640. @Endnode
  641. @Node Internet "More addictive than heroin"
  642. The Internet:
  643. The Internet is by far the world's largest electronic network.  It
  644. incorporates an e-mail system from which you can contact people all over the
  645. world almost instantly.  It has an estimated population in the tens of
  646. millions, and grew out of the ARPAnet, a network founded in the late 1960's
  647. by the US Defense Advanced Research Projects Agency.  More information can be
  648. found in the @{" EFF " Link EFF}'s "Big Dummy's Guide to the Internet".
  649. [Sheesh, James: you _have_ been doing your homework! :-) ]
  650. @Endnode
  651. @Node Usenet "I was so busy today, I only had three hours to read Usenet..."
  652. Usenet:
  653. Usenet is a global conferencing system, accessed via the @{" Internet " Link Internet}.  It
  654. contains thousands of "newsgroups", where people can leave public messages
  655. for others to read.  Topics include computers (obviously!), music, TV,
  656. cooking, animals, and much, much more.  It is a goldmine of information, as
  657. you can post a message on any newsgroup and expect replies back within 24
  658. hours.
  659. @Endnode
  660. @Node EFF "The net.police are after you!"
  661. The EFF:
  662. The EFF (Electronic Frontier Foundation) is an organisation set up in 1990 to
  663. deal with the growing problems of e-mail networks, to represent them, offer
  664. legal advice to those accused of computer crime, and to publicise e-mail as
  665. the way ahead for communications.
  666. @Endnode
  667. @Node Fidonet "Who let that dog in here?"
  668. FidoNet:
  669. FidoNet is the world's largest amateur e-mail network, with around 24,000
  670. nodes (main carriers of the e-mail; these are mostly @{" BBSes " Link BBS}), and countless
  671. numbers of users, many of which are @{" Points " Link Point}.
  672. @Endnode
  673. @Node BBS "There's a whole new world out there!"
  674. BBSes:
  675. A BBS (Bulletin Board System) is a system where people with modems (a
  676. device to translate digital computer data into an analogue signal which the
  677. telephone network can understand) can dial in to send and receive files and
  678. messages, as well as playing online games and talking to other users who are
  679. logged in at the same time.
  680. @Endnode
  681. @Node Point "When the phone bill gets too big"
  682. Points:
  683. A point is basically an automated offline mail-reader.  A piece of software
  684. calls the @{" BBS " Link BBS} for you to download any waiting mail in a compressed packet.
  685. At the same time, it uploads your replies to the last packet of mail you
  686. received, and can even request files from the BBS's file areas.  If you leave
  687. your computer on all night, you can set up a system whereby the call is made
  688. for you in the middle of the night (when the phone charges are the
  689. cheapest!), and when you wake up in the morning, your mailreader is sitting
  690. there ready for you to read the mail!
  691. @Endnode
  692. @Node LacePointer "For every flicker-fixer user"
  693. LacePointer:
  694. When running in interlace mode on non-AGA Amigas, the pointer is still a low-
  695. resolution sprite.  For people with flicker-fixers installed (e.g. the
  696. A3000's Display Enhancer), this detracts from the professionality of the
  697. system.  LacePointer is a system hack which effectively makes the pointer
  698. appear to be in a higher resolution (by putting it in interlace mode too).
  699. @Endnode
  700. @Node SnoopDos "Eddy Carroll's masterpiece"
  701. SnoopDos:
  702. SnoopDos is a utility that allows you to monitor a variety of system
  703. operations carried out by programs on your Amiga.  This includes what files a
  704. program is trying to open, what fonts, libraries, devices and environment
  705. variables it is looking for, and so on.
  706. It is invaluable when trying to find out why a particular program won't work,
  707. or when you are suspicious about what something is doing to your hard drive.
  708. SnoopDos should be available through the same channels as PriMan, or you can
  709. e-mail its author at <ecarroll@maths.tcd.ie>.  The source code is included
  710. (in a separate archive), and is a goldmine of useful information for budding
  711. Amiga programmers.
  712. @Endnode
  713.